package ch5;

import java.util.Scanner;

public class WhileYzhi {

	public static void main(String[] args) {
		Scanner in = new Scanner(System.in);
		int k = 0;
		while (true) {
			System.out.println("input a weekday:");
			k = in.nextInt();
			if (k == 0)
				break;

			switch (k) {
			case 1:
				System.out.println("周一");
				break;
			case 2:
				System.out.println("周2");
				break;
			case 3:
				System.out.println("周3");
				break;
			case 4:
				System.out.println("周4");
				break;
			case 5:
				System.out.println("周5");
				break;
			case 6:
				System.out.println("周6");
				break;
			case 7:
				System.out.println("周7");
				break;
			default:
				System.out.println("输入的数字不合格！~");
				break;
			}
			/*
			 * if (k >= 1 && k <= 7) {
			 * 
			 * }
			 */
		}

	}

}
